A proof theoretical approach to Continuation Passing Style

نویسنده

  • Ichiro Ogata
چکیده

In this paper we study the relation with continuation passing style(CPS) and classical proofs, proof theoretically. There is two style of CPS translation { Call by name (CBN) and Call by value(CBV). We revealed that in the case of classical proofs, this two reduction strategy may induce di erent result even if the language is purely functional(i.e. proof theoretical). We explain this through the witness of peirce's law as a program with the help of computational property of classical linear logic. In Curry-Howard correspondence, CPS translation on programs is conversion on classical proofs. We show that CBN/CBV CPS translation precisely corresponds to proof conversion from classical logic(LK) into two style of restricted classical logic: LKT/LKQ respectively. LKT/LKQ [5], and its accompanying linear decoration, presented by Danos, Joinet and Schellinx are variation on Gentzen's original system LK. LKT/LKQ enrich two coloring (T and Q) to the formula of LK and is still complete for classical provability. The key idea to show that this proof conversion being CBN/CBV, is intuitionistic decoration which maps LKT/LKQ proofs into equivalent (w.r.t the cut elimination procedure) LJ proofs. Resulting LJ proofs is exactly the one known as the result of CBN/CBV translation. Since LKT/LKQ also has classical linear decoration which is more precise from the point of view of computation, this gives us an idea to construct CBN/CBV term calculus inheriting computational property of linear logic. We present con uent, strongly normalizing LKQ term calculus (CBV calculus on classical proofs) in Gentzen-style sequent as the subsystem of Proof Net of Girard[9].

برای دانلود متن کامل این مقاله و بیش از 32 میلیون مقاله دیگر ابتدا ثبت نام کنید

ثبت نام

اگر عضو سایت هستید لطفا وارد حساب کاربری خود شوید

منابع مشابه

The Occurrence of Continuation Parameters in Cps Terms

We prove an occurrence property about formal parameters of continuations in Continuation-Passing Style (CPS) terms that have been automatically produced by CPS transformation of pure, call-by-value-terms. Essentially, parameters of continuations obey a stack-like discipline. This property was introduced, but not formally proven, in an earlier work on the Direct-Style transformation (the inverse...

متن کامل

On proving syntactic properties of CPS

Higher-order program transformations raise new challenges for proving properties of their output, since they resist traditional, rst-order proof techniques. In this work, we consider (1) the \one-pass" continuation-passing style (CPS) transformation, which is second-order, and (2) the occurrences of parameters of continuations in its output. To this end, we specify the one-pass CPS transformati...

متن کامل

A Simple Correctness Proof of the Direct-Style Transformation

We build on Danvy and Nielsen’s first-order program transformation into continuation-passing style (CPS) to present a new correctness proof of the converse transformation, i.e., a one-pass transformation from CPS back to direct style. Previously published proofs were based on CPS transformations that were either higher-order, noncompositional, or operating in two passes, and were correspondingl...

متن کامل

Educational Pearl: 'Proof-directed debugging' revisited for a first-order version

Some 10 years ago, Harper illustrated the powerful method of proof-directed debugging for developing programs with an article in this journal. Unfortunately, his example uses both higher-order functions and continuation-passing style, which is too difficult for students in an introductory programming course. In this pearl, we present a first-order version of Harper’s example and demonstrate tha...

متن کامل

Correctness of a region-based binding-time analysis

A binding-time analysis is the rst pass of an ooine partial evaluator. It determines which parts of a program may be executed at specialization time. Region-based binding-time analysis applies to higher-order programming languages with rst-class references. The consideration of eeects in the determination of binding time properties makes it possible to have a partial evaluator perform assignmen...

متن کامل

ذخیره در منابع من


  با ذخیره ی این منبع در منابع من، دسترسی به آن را برای استفاده های بعدی آسان تر کنید

برای دانلود متن کامل این مقاله و بیش از 32 میلیون مقاله دیگر ابتدا ثبت نام کنید

ثبت نام

اگر عضو سایت هستید لطفا وارد حساب کاربری خود شوید

عنوان ژورنال:

دوره   شماره 

صفحات  -

تاریخ انتشار 2007